package com.example.demo.config.mongo;

import org.springframework.context.annotation.Configuration;
import org.springframework.data.mongodb.repository.config.EnableMongoRepositories;

/**
 * 配置不同包路径下使用不同的数据源
 * Created by Administrator on 2018/06/25 0025.
 */
@Configuration
@EnableMongoRepositories(basePackages = "com.example.demo.repository.primary",
        mongoTemplateRef = PrimaryMongoConfig.MONGO_TEMPLATE)
public class PrimaryMongoConfig {
    protected static final String MONGO_TEMPLATE = "primaryMongoTemplate";
}
